package com.zhihao.zhihaopicturebackend.model.dto.picture;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.List;

/**
 * @author Jackson
 * @create 2024/12/23 16:25
 * @description 图片更新请求类
 */
//@ApiModel("图片更新请求类-非图片元信息-管理员使用")
@Data
public class PictureUpdateRequest implements Serializable {

    /**
     * id
     */
    @ApiModelProperty(value = "图片id")
    @NotNull(message = "id 不能为空")
    @Min(value = 1, message = "id 必须大于等于0")
    private Long id;

    /**
     * 图片名称
     */
    @ApiModelProperty(value = "图片名称")
    @Size(max = 50, message = "图片名称过长")
    private String name;

    /**
     * 简介
     */
    @ApiModelProperty(value = "图片简介")
    @Size(max = 800, message = "简介过长")
    private String introduction;

    /**
     * 标签(表中字段为Json格式字符串，此处转化为List)
     */
    @ApiModelProperty(value = "图片标签")
    private List<String> tags;

    /**
     * 分类
     */
    @ApiModelProperty(value = "图片分类")
    @Size(max = 50, message = "分类名称过长")
    private String category;

    /**
     * 空间 id
     */
    @ApiModelProperty(value = "空间id")
    private Long spaceId;
  
    private static final long serialVersionUID = 1L;  
}
